#ifndef _BUOLA_CV_IO_CWEBCAM_H_
#define _BUOLA_CV_IO_CWEBCAM_H_

#include <buola/buola.h>

#include <buola/utility/usignal.h>
#include <buola/image/format.h>

namespace buola { namespace cvi {

class CWebCamDevice;
    
class CWebCam
{
public:
    CWebCam(const io::CURI &pDevice);
    ~CWebCam();
    
    void Start();
    void Stop();
    img::CImage_rgb8 GetOne();
    
    USignal<void(const img::CImage_rgb8&)> sImage;

private:
    CWebCamDevice *mDevice;
    bool mStarted;
};

/*namespace cvi*/ } /*namespace buola*/ }

#endif
